#ifndef COMMUNICATLIST_H
#define COMMUNICATLIST_H

#include <QWidget>
#include <QCloseEvent>
#include <QVector>
#include <QToolBox>
#include <QLabel>


#include "widget.h"
namespace Ui {
class communicateList;
}

class communicateList : public QWidget
{
    Q_OBJECT

public:
    explicit communicateList(QWidget *parent = nullptr);
    void set_baseInformation(const QString& username,const QString& nickname,const QString& avator_path,const QString& last_login_time);
    void Chat();
    bool Request();
    void PersonMessage();
    ~communicateList();
protected:
    void closeEvent(QCloseEvent* event) override;
signals:
    void UpdateRequest();
private:
    Ui::communicateList *ui;
    QVector<bool> isShow;
    QString username="";
    QString nickname="";
    QString avatar_path="";
    QString last_login_time="";
    QVector<std::tuple<QString,QString,QString>> qvec;
    QVector<std::tuple<QString,QString,QString,int>> request;
    int currentIndex=0;
    bool change_chat=false;
    bool change_request=false;
    bool change_msg=false;
};

#endif // COMMUNICATLIST_H

